import Vue from 'vue'
import vueRouter from './vueRouter'
// import vueRouter from 'vue-router'
import App from './App.vue'
import Home from './components/Home.vue'
import About from './components/About.vue'

Vue.use(vueRouter)

Vue.config.productionTip = false

const routes = [
  {
    name: 'Home',
    path: '/',
    component: Home
  },
  {
    name: 'About',
    path: '/about',
    component: About
  }
]

const router = new vueRouter({
  // mode: 'history',
  routes
})

const vm = new Vue({
  router,
  render: h => h(App),
  data: {
    msg: 'hello'
  },
  methods: {
    greet: function () {
      
    }
  }
}).$mount('#app')

console.log(vm)
